home *** CD-ROM | disk | FTP | other *** search
/ Workbench Add-On / Workbench Add-On - Volume 1.iso / BBS-Archive / Dev / GNU-TILE-FORTH.lha / src / memory.c < prev    next >
C/C++ Source or Header  |  1992-05-19  |  2KB  |  63 lines

  1. /*
  2.   C BASED FORTH-83 MULTI-TASKING KERNEL MEMORY MANAGEMENT
  3.  
  4.   Copyright (C) 1989-1990 by Mikael R.K. Patel
  5.  
  6.   Computer Aided Design Laboratory (CADLAB)
  7.   Department of Computer and Information Science
  8.   Linkoping University
  9.   S-581 83 LINKOPING
  10.   SWEDEN
  11.  
  12.   Email: mip@ida.liu.se
  13.   
  14.   Started on: 8 November 1989
  15.  
  16.   Last updated on: 26 June 1990
  17.  
  18.   Dependencies:
  19.        (cc) memory.h, io.h, kernel.h
  20.  
  21.   Description:
  22.        Handles low level access to memory and dictionary allocation.
  23.   
  24.   Copying:
  25.        This program is free software; you can redistribute it and/or modify
  26.        it under the terms of the GNU General Public License as published by
  27.        the Free Software Foundation; either version 1, or (at your option)
  28.        any later version.
  29.  
  30.        This program is distributed in the hope that it will be useful,
  31.        but WITHOUT ANY WARRANTY; without even the implied warranty of
  32.        MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  33.        GNU General Public License for more details.
  34.  
  35.        You should have received a copy of the GNU General Public License
  36.        along with this program; see the file COPYING.  If not, write to
  37.        the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. 
  38.  
  39. */
  40.  
  41.  
  42. #include "kernel.h"
  43. #include "io.h"
  44. #include "memory.h"
  45.  
  46. VOID memory_initiate(size)
  47.     INT32 size;
  48. {
  49.     /* Allocate dictionary area and setup dictionary pointer */
  50.  
  51.     dictionary = (PTR32) malloc((unsigned) size);
  52.     if (dictionary == NIL) {
  53.     (VOID) fprintf(io_errf, "memory: cannot allocate dictionary area\n");
  54.     exit(0);
  55.     }
  56.     dp = dictionary;
  57. }
  58.  
  59. VOID memory_finish()
  60. {
  61.     /* Future clean up function for memory management package */
  62. }
  63.